//
//  YWSelectCollectionViewCell.m
//  聆听FM
//
//  Created by dllo on 16/6/12.
//  Copyright © 2016年 Dark. All rights reserved.
//

#import "YWSelectCollectionViewCell.h"


@implementation YWSelectCollectionViewCell

- (instancetype)initWithFrame:(CGRect)frame
{
    self = [super initWithFrame:frame];
    if (self) {
        self.textLabel = [[UILabel alloc] initWithFrame:CGRectMake(0, 0, self.bounds.size.width, self.bounds.size.height)];
        _textLabel.textAlignment = 1;
        _textLabel.backgroundColor = [UIColor colorWithWhite:0.933 alpha:1.000];
        [self.contentView addSubview:_textLabel];
    }
    return self;
}

- (void)setHotListModel:(YWHotTopListModel *)hotListModel
{
    if (_hotListModel != hotListModel) {
        _textLabel.text = hotListModel.name;
    }
}

- (void)setIsSelect:(BOOL)isSelect
{
    if (isSelect == YES) {
        _textLabel.backgroundColor = [UIColor orangeColor];
        _textLabel.textColor = [UIColor whiteColor];
    }
    else
    {
        _textLabel.backgroundColor = [UIColor colorWithWhite:0.933 alpha:1.000];
        _textLabel.textColor = [UIColor blackColor];
    }
}

@end
